package com.ohuang.test_koin

import androidx.lifecycle.ViewModel
import androidx.lifecycle.viewModelScope
import com.ohuang.test_koin.data.User
import com.ohuang.test_koin.presenter.UserPresenter
import kotlinx.coroutines.launch

class MainViewModel( val presenter: UserPresenter):ViewModel() {


    fun addUser(){
        viewModelScope.launch {
            presenter.addUser(arrayListOf(User("aaa"), User("bbb"), User("ccc")))
        }

    }

}